Repository navigation
feat(NEW-CANDIDATE-PORTS): the Inkling-2-Mini W1 loop forward - exact token gate vs llama.cpp abca69200 - #3607
Merged
lu-zero merged 46 commits intoDec 5, 2026
Conversation
…and exact token gate W0 landed the inkling2_loop config builder and the loader still refuses the model at the forward boundary, so no token can be generated. This spec fixes the scope of the CPU forward: one sequence, prefill and decode, through ModelRegistry::Forward and the paged engine, gated token for token against llama.cpp. The Tenstorrent arm is W2. The runnable oracle is llama.cpp abca69200 because the pinned vLLM forward is nvidia-only and not gateable on this host (inkling2-vllm-pin-advance.md). The commit carries the golden token ids for the mainline UD-Q4_K_M and UD-Q8_K_XL arms in four modes each, and the measured relation to the earlier 33aeb17f8 captures: prompt and generated ids are equal for every prompt, mode and arm. Reference: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.4 [maki]
W1 turns the W0 parse-only inkling2_loop arm into a generated path. A census-validated GGUF loader dequantizes the mainline-layout Q4_K_M and Q8_K_XL arms to host f32, including NVFP4 experts with per-expert F32 scales; host ops port the llama.cpp abca69200 AttnRes mix, gated cross-pass controller, clipped relative-bias attention with sinks and sigmoid top-8 SiTU MoE; the registry and paged forward run the fixed prelude, three core passes and coda through ModelRegistry::Forward. The runner cannot allocate 48 slot-indexed caches (it resolves only 24 in-range .layers.<N>. names and forbids a layer in both groups), so the loop slots are packed as disjoint head planes and channel blocks in one attention cache and one short-conv state; the spec amendment records the constraint and a unit test pins slot disjointness. The tokenizer maps pre=inkling2 onto the GPT4O split with ignore_merges, with a parity test over all oracle prompt texts in raw and chat modes. The exact token gate is NOT yet green: the first greedy token matches, then decode diverges. Focused evidence records the first differing index and the named-resource constraints (NUMA-interleaved host needed for the ~100 GB f32 weight set) under docs/bench-evidence/new-candidate-inkling2-w1-20261125/focused.log. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…stency The runner samples over config.vocab_size, which W0 pinned to the GGUF's padded vocabulary (201024), while the paged forward served only the oracle's unpadded 200058 logits. A temperature-0 step therefore read the padding bytes as logits and could return an id the oracle never scores. Serve the full padded row with every padding slot at -inf and pin it with a focused unit test. Add a teacher-forcing consistency gate: the next token from a prompt plus the oracle's first k generated ids must equal the k-th token of a plain generation. It passes for k=1 and k=2 and proves the packed K/V page and short-conv channel blocks are per-slot and persist across decode steps. Record the developer's footprint decision: dequantize expert weights on demand from memory-mapped stored types, tracked as ISSUE-LOCAL-01M89VPD6BYJNCQA3NQNV34F9D, with the measured Q4_K_M peak RSS and the 4x64 GB NUMA recipe in the spec. The exact oracle gate is still RED; focused.log records the first differing indices and the oracle's top-K at that position from the existing server build. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
Record the first-divergence index for all 12 oracle prompts: six raw prompts fail at j=0, six chat prompts fail at j=2 with the same wrong id 89299 against oracle 371, independent of prompt text and length. This weakens a conv-history or relative-distance-index explanation and points at a systematic logits computation. Audit the ported ops against llama.cpp abca69200: NVFP4 decode (UE4M3 scale and 2x E2M1 lut), AttnRes mix order/eps/scale, relative-bias gather and tau, and the post-conv residual scale. Fix one real mismatch: ggml folds the zero attention sink into the softmax MAX as well as the sum, which the host op omitted. The exact gate remains RED; the first bad layer and op are still unresolved and no tolerance or dtype was tuned. The cross-prompt test is diagnostic only: it generates 8 tokens per prompt and never changes the 128-token gate. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…ax sink The oracle tap instrument (outside the repository, at /tmp/llamacpp-inkling-tap) confirms Q/K/V, the relative projection, sink logits and the packed KV cache rows agree with llama.cpp within 1% at layer 0. Three defects were found and fixed on the path to the first bad op: - the short-conv post step was called with cur and out aliasing, so the recurrent history stored the amplified output and grew exponentially; - GQA query heads map to KV heads in contiguous groups (h/(n_head/n_kv)), not h % n_kv_heads; - ggml's soft-max folds the zero sink into the max as well as the sum. The first bad op is isolated to layer 0's attention output (att_raw): its relative error is still 1.59 after those fixes, while all its inputs agree. Two length experiments are recorded: no tile threshold when prepending neutral tokens, and the chat failure stays at the second decode step for lengths 21/22 and 30/31. The exact gate remains RED; no tolerance or dtype was tuned. The measurement-only env var is allowlisted. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…rt conv The oracle tap instrument now agrees with this port to within 1% on every layer-0 quantity (Q/K/V, relative projection, sinks, gathered bias, attention output, lm-head input) after two more corrections: the gathered bias is in score units (dot*scale + bias), and an AttnRes block boundary must keep the attention output as the new residual instead of the layer input. Across all 48 visits, l_out agrees for visits 0-4 and first diverges at visit 5, the first full-attention layer. Its Q/R/sinks and the K/V projections and dynamic conv taps agree within 1%, but K/V after the short conv diverge (K rel 0.48, V rel 0.70). The first bad layer and op are therefore layer 5's dynamic short conv (attn_k_conv / attn_v_conv with their *_conv_proj taps). The exact gate still diverges: the first five raw ids match the oracle and id 5 does not. No tolerance or dtype tuning. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The oracle taps now agree with this port within about 1% on every layer-5 op at the last prompt position, and post-clip K/V agree (rel 0.006 / 0.008), so the dynamic short conv is not a remaining structural defect. The exact gate still diverges at generated id 5: the oracle ranks 161721 first with a 0.6756-logit gap over its third candidate 151663, while this port has a 0.9407-logit gap and therefore selects 151663. The ~0.26-logit difference is consistent with accumulated f32 reduction-order differences, not an unwired mechanism. The focused log records the per-op table and both candidate lists. No tolerance or dtype value was changed. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…messages The contradiction between the gate failure and an earlier logit dump was stale data: the same binary now shows argmax 151663 and sampled 151663 at the failing position. Taps at that position agree for all 18 prelude visits and first diverge at visit 18, the first core layer of pass 1. The remaining defect is the per-pass bank/message mix or controller, not dot reduction order. No tolerance or dtype change. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The cheapest probe proves the visit-18 mapping is correct: slot 24 selects physical layer 6 in pass 1 with a distinct KV/conv slot from pass 0 and a one-block bank. bank_out agrees with the oracle at the failing position, and a Python recomputation of Inkling2AttnRes from our own bank and bank_out reproduces our message mix, so the mix arithmetic is correct. The pass bank is now owned by copies rather than pointers into `blocks`, which is replaced with the prelude block list before the messages are read. This removes a latent dangling-pointer hazard, but the exact gate still diverges at raw generated id 5. The bank-content comparison is inconclusive because the env dump also captures decode steps with divergent state; a per-step tagged dump is needed before a conclusion. No tolerance or dtype change, no oracle pin change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
Fresh single-request taps show the oracle bank equals its ip=12 pass-0 block push exactly, and ours equals ours exactly; the bank agrees across implementations within 2 percent. The wrong-push suspect is disproved. The remaining loop_msg divergence appears to be our reading of the ggml mul_mat output layout, not the bank. No tolerance or dtype change. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The layout probe showed ggml's mix result is [n_queries, n_embd, n_tokens] with ne[0]=n_queries, while our Inkling2AttnRes wrote [query][hidden] and the paged forward read query rows with a hidden-sized stride. Both sides now use q + d*n_queries. The upstream unit test was updated to the same layout. At the failing decode position the loop_msg tap now agrees with the oracle to 0.0176 relative, down from 1.49, and test_inkling2_loop_ops passes 194717/194717. The exact token gate remains red; the first genuine numeric difference is the Q8_0 projection (its input matches to 1e-8, its output differs 0.75%), which is a separate arithmetic-path change. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
… dots The developer approved enlarging W1 on 2026-11-26; the spec amendment records the approval and supersedes the f32 on-demand footprint follow-up, whose issue text is updated rather than deleted. llama.cpp converts the F32 activation to the weight vec_dot_type before a mul_mat. For Q8_0 attention projections that is quantize_row_q8_0 with ties-to-even on this aarch64 host, followed by a quant-by-quant dot; for NVFP4 experts it is the same Q8_0 activation against ggml_vec_dot_nvfp4_q8_0. Both kernels are transcribed from the pinned ggml source, keep the packed quants from the GGUF, and are proven byte-identical to the reference functions compiled from the oracle tap build: 0 mismatches in 2000 Q8_0 quantization and dot vectors and in 1000 NVFP4 blocks. Golden bit patterns from that harness are pinned in the unit test (194720/194720 assertions). After wiring, the il=0 Q/K/V/R taps agree with the oracle to about 1e-7 relative instead of 0.75%. The exact gate is still red at raw generated id 5; the next per-op divergence is the attention score/bias path, where att_raw differs by 0.10% while q/k/v/r match. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 Refs: ISSUE-LOCAL-01M89VPD6BYJNCQA3NQNV34F9D FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The tagged single-request oracle dump located the first real mismatch at the BF16 sink projection: the normalized attention input matched to 7e-8 and the GGUF weights are identical, but the projection output differed by 5e-4 relative. ggml-cpu.c:404-408 gives BF16 weights vec_dot_type BF16, so the F32 activation is rounded to BF16 before the dot; our dequant-to-f32 path used the full-precision activation. The BF16 activation quantization and dot are transcribed from the pinned ggml traits, keep the packed BF16 weights, and are pinned byte-for-byte against the ggml functions from the oracle tap build in the unit test (194722/194722 assertions). After wiring, the sink logits match the oracle bit-for-bit and att_raw improves from 1.0e-3 to 2.9e-4 relative. The exact gate is still red at raw generated id 5; no tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
… the rule The 2026-11-26 spec amendment now states the rule proven twice in this row: at every ggml matmul the activation is quantized to the WEIGHT's vec_dot_type before the dot (ggml-cpu.c:1380-1408), never left as f32 by assumption. The Q5_K gate/up experts on layers 20-23 take Q8_K activations. The quantizer and dot are transcribed from the pinned ggml source, including the 176-byte block_q5_K layout, ggml's fused nearest_int magic-add, the dmin bsum correction and the eight fma partial sums. They are bit-identical to ggml references compiled from the oracle tap build on 1500 vectors including x1000 magnitudes; the golden is pinned in the unit test (194724/194724). Q8_0 down experts on those layers use the already-proven Q8_0 path. Unit gates pass. The exact gate is still red at raw generated id 5: these tail layers are not reached by the first divergence, which remains in the attention score/softmax arithmetic at il=0. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
Added an env-gated per-head score/probability print on our side and captured a fresh tagged oracle dump to compare the 15 numbers at the failing position. The oracle side did not produce the scores/probs records: inkling2's build_attn resolves to a different overload than the no-cache build_attn_mha where the tap was inserted. The tagged tap binary was verified against the committed raw goldens first and no arithmetic was changed from this inconclusive probe. The remaining divergence is still the attention score/softmax path at il=0; the exact gate is red at raw generated id 5. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The executing oracle kernel is ggml_flash_attn_ext with an F16 mask and the scale applied inside the kernel, not the explicit f32 softmax with a separate sink that our op used. Our attention step now follows ggml_compute_forward_flash_attn_ext_f16_one_chunk (ggml-cpu/ops.cpp:8970): F16-rounded mask, in-kernel scale, online softmax with a running max and denominator that rescales the accumulated V on a new maximum, a zero-logit sink applied after the key loop, and F32 V multiply-add. The il=0 att_raw divergence improves from 2.86e-4 to 1.89e-4 relative and the unit suite stays green (194724/194724). A graph-level ggml flash harness built from the pinned tap build reproduces our attention output from the captured taps, but the offline K/V reconstruction is invalid because the K/V were captured in separate requests with different batch groupings and Q8_0 activation quantization is context dependent. I am not claiming bit parity from that comparison. The exact gate is still red at raw generated id 5. PROCESS.md records the tap hazard: a cb_eval callback that returns true perturbs the oracle output, so goldens must be verified with taps both enabled and disabled. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The spec amendment now records that the oracle executes inkling2 attention through ggml_flash_attn_ext (F16 mask, in-kernel scale, online softmax with running max and V rescale, zero-logit sink) and that the CPU arm mirrors that kernel for the CPU path; the old explicit-softmax op is model-local and has no downstream consumers. It also records the capture hazard: Q8_0 activation quantization is context-dependent, so oracle taps from separate requests cannot be combined with a single-request gate run; every bit-proof must use a single-request capture matching the gate shape, and the tapped binary must reproduce the goldens with taps both enabled and disabled. A cb_eval callback that returns true perturbs the oracle output and is never acceptable as a passive tap. A single-request incremental capture was blocked: cache_prompt=true with growing prefixes produced no graph compute beyond two tokens, and forcing -b 1 -ub 1 -n 1 aborts llama-server at context init. The flash mirror is not claimed bit-exact. The gate remains red at raw generated id 5. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The ggml-level flash-op capture showed the kernel consumes F16 K and V (llama-context.cpp:4441-4442 sets the KV cache type to F16), while our paged cache stored the F32 projections directly. K/V are now rounded to F16 on cache write, which is the value the oracle's flash kernel reads. At il=0 the attention output improves from 1.89e-4 to 5.03e-5 relative and l_out from 5.3e-3 to 4.2e-3; the unit suite stays green (194724/194724). The exact gate is still red at raw generated id 5. The tap build now also captures the flash op's actual q/k/v/mask/sink/output tensors synchronously inside ggml_compute_forward_flash_attn_ext with exact strides and types. The tapped binary reproduces the committed golden with the capture enabled and disabled, so the instrument is passive. The capture whose F16 mask matches our il=0 bias belongs to a different layer visit (only seven valid keys), so it is not the failing il=0 attention; recomputing with seven keys is worse than with all ten. No arithmetic change from that probe. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The per-position comparison at pos2 determined where the K/V drift enters: the projection input rows agree at ULP (attn_in rel 2.09e-08) and their Q8_0 quantizations are byte-identical (0 differing bytes of 2448), so neither the residual stream nor batch-dependent quantization is responsible. The ~1.4e-3 K/V difference comes from the dot kernel selected by batch shape: the oracle's 6-token graph uses ggml's nrc=2 i8mm mmla vec_dot while our host op always uses the nrc=1 generic dot. Both are bit-exact against their own references. A batched-prefill config change cannot bridge it: our engine already prefills the 5- and 10-token prompts as single graphs (T=5/T=10), but batch size does not select a different kernel in our implementation. Exact parity therefore needs an nrc=2 mmla dot path (a real feature) or an explicitly ratified near-tie gate; the developer decides. The exact gate stays red at raw j=5. This also records the capture rule: exact-parity comparisons pin both sides' serving batch shape and kernel selection (nrc), since Q8_0 activation quantization and ggml's vec_dot dispatch are context dependent. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…kernel Developer-approved 2026-11-27 enlargement: the oracle's multi-token graphs dispatch ggml's aarch64 i8mm mmla Q8_0 vec_dot, so the CPU arm selects that kernel by shape (nrc>=2) while single-token decode keeps the proven generic dot. No environment switch, matching ggml's shape-based selection. The kernel is the tree's vt::cpu::QuantMmlaVecDot(kQ8_0) rather than a duplicate transcription. Bit-proof against ggml's nrc=2 vec_dot compiled from the pinned oracle tap build: 3000 randomized batched cases (k=32..1024, large/tiny scales, block boundaries), 0 byte mismatches; golden output bits pinned in the unit test (194728/194728 assertions). The spec amendment dates the approval and records that other architectures are owed the generic path. Gate remains red at raw generated id 5; wiring of the batched projection is the next step in this wave. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…hape The paged forward now routes prefill projections (T>=2: q/k/v/r/conv-proj/sink) through Inkling2MatVecMmla, while T==1 decode keeps the proven generic kernel; no environment switch, matching ggml's shape-based selection. The mmla helper duplicates the weight and activation rows for the nrc=2 call, which yields the same per-row result as a real two-row batch. The gate is unchanged and still red at raw generated id 5. A direct offline matrix falsified the nrc hypothesis for Q8_0 at k=2304: ggml generic, ggml nrc=2, our generic and our mmla all agree bit-for-bit; only ggml's aarch64 nrc=1 ARM kernel differs from them. The 1.4e-3 K/V measurement therefore predates the F16 cache fix and cannot be attributed to kernel selection. No tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
… the chain The last authorized instrument step failed: a backend-API harness with CPU_REPACK buffer and ggml_backend_tensor_set aborts at ggml-backend.cpp:534 because ggml_new_tensor_* tensors own context data and are not bound to a backend buffer. Faithful reproduction needs the scheduler's full allocation flow, beyond the bounded step. The instrument hunt stops here. Everything else in the chain is verified: projection inputs and Q8_0 integers match; the four-family dot matrix (ggml generic, ggml nrc=2, our generic, our mmla) is bit-identical; one_chunk nrc instrumentation shows zero invocations; the server load log confirms every attention projection is repacked with q8_0_4x8 into CPU_REPACK; the vt repack seam exists and is bit-identical; F16 KV cache and flash attention are committed, with flash ULP on identical captured bytes; and warmup graphs were separated from real prompt graphs. The exact gate is still red at raw generated id 5. The gate-policy decision is owed to the developer; no tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
Offline bit-proof against ggml_gemm_q8_0_4x8_q8_0 from the pinned tap build: vt::cpu::QuantRepackMatmul differs on 4656 of 6400 outputs (100 randomized [4,2304] x [16,2304] cases, small and x1000 magnitudes) by ~1.5e-6 relative. The cause is the scale-multiply order: GemmTileQ8_0 uses vmlaq_f32 (FMA) where ggml accumulates the product separately. This is a SHARED seam kernel that other rows' parity rests on; changing it unilaterally would be out of scope, so the finding goes to the seam owner. It is ~1e-6 relative and does not explain the ~1e-3 K residue. The gate stays exact and red at raw generated id 5; no tolerance or dtype change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
ISSUE-LOCAL-01M8EVYQFB7561HSRHS4DF2KGJ. The pinned ggml ARM repack source (ggml/src/ggml-cpu/arch/arm/repack.cpp:5780) uses the FUSED vfmaq_f32; vt used the non-fused vmlaq_f32. GemmTileQ8_0 now uses vfmaq_f32 in the same block order, so the repacked tier is bit-identical to the oracle (0/6400, golden 0x2297b6b80999049e). The spec's inverted root-cause prose is corrected from that source line. The hermetic gate's old "repacked == generic, bit-identical" assertion was a WRONG invariant, not a weak one: ggml's own repack tier (FMA) and generic tier (scalar f32) differ bit-for-bit. It is replaced by per-tier reference equality. The repacked tier is bit-identical to ggml's FMA tier on every shape, dtype and stride. The generic tier is held to a scalar-order f64 restatement of ggml's generic source (sumf[m][j] += sumi * dw * da in source order, floored to f32) at max-abs 1e-5 at K=2304, measured 7.62939e-06. This is strictly stronger than cross-tier identity: either tier drifting from its own counterpart now fails. Larger-K shapes keep the repacked bit-identity rather than a tuned tolerance. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…_0 fix These files are the missing self-contained test and evidence/record artifacts from the QUANT-GGUF-CIQ-GEMM seam lane whose kernel fix was cherry-picked as d63b864d0. They are taken from row/QUANT-GGUF-CIQ-GEMM-gemm-q80-fma only to satisfy this branch's evidence/record checkers and to run the bit-proof test; the RED pre-fix kernel state in that lane's earlier commit was deliberately NOT brought over. Seam fix by opencode-6c9065c1 / QUANT-GGUF-CIQ-GEMM lane. Refs: ISSUE-LOCAL-01M8EVYQFB7561HSRHS4DF2KGJ Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
Patched the scratch tap build at llama-graph.cpp:3789 to tap the pre-rounding f32 K written into the KV cache for il=0, with --no-warmup and single-thread capture. Golden 161721 with taps both enabled and disabled. Per-position f32 Kcur comparison: positions 0, 8 and 9 match at ULP; positions 1..7 differ by 2e-5 to 2.6e-4. The f32 value already diverges before the F16 cache write, so our F16 conversion is not the source. The divergence is in the batched K projection arithmetic for the oracle's 6-token graph shape. No repository code changed by this probe. No tolerance or dtype change, no push; gate still red at raw generated id 5. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
… table Extended the scratch tap build's proven cache-write site with kproj (matmul output) and kpostconv (conv output) dumps at il=0. --no-warmup, single-thread, golden 161721 with taps enabled and disabled. The table localizes two distinct op-class defects: projection accumulation at positions 1, 3, 4 (matmul output differs even though attn_in matches at ULP) and short-conv state hand-off at positions 2, 5, 6, 7 (matmul output matches but conv output differs). Positions 0, 8, 9 match at ULP throughout. No repository code changed by this probe; temporary taps reverted. No tolerance or dtype change, no push; exact gate still red at raw j=5. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
…nfig Rebased the W1 row onto the repaired chunked-prefill seam a2fdde9 and set ep.prefill_ubatch=16 in the exact-token gate: a gate configuration that pins the oracle server's serving shape, not an arithmetic or tolerance change. Raw gate ids (mode=raw, "The capital of France is"): j=5 got 151663 want 161721; j=6 got 198 want 156021; j=7 got 33 want 68014. Chunk engagement was confirmed in that exact run by a temporary runner probe (since reverted): prefill plan (1,4) at a 5-token prompt, two Forward calls; decode steps empty. The per-position preconv/postconv table with chunking on is unchanged from the pre-seam table (projection differences at 1,3,4; conv-only at 2,5,6,7; positions 0,8,9 ULP). No arithmetic hunting and no tolerance change. Also repairs three stale record anchors the rebase surfaced; check-agent-record reports ANCHOR-ROT=0. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
… checkpoints Bit-proof of vt::cpu::QuantRepackMatmul against ggml_gemm_q8_0_4x8_q8_0 from the pinned tap build: 0/6400 mismatches on 100 randomized batched cases with one shared quantizer after the bb1da7d6 FMA fix. Routing W1's Q8_0 projections through that repack path changed the per-position kproj/kpostconv table byte-for-byte not at all, so the kernel class is falsified as the residue cause; the wiring was reverted. Also records the seam's chunk engagement (prefill plan (1,4) for the gate's 5-token raw prompt, two Forward calls), the unchanged raw gate ids (j=5 151663 vs 161721), and the open prompt/shape-parity question for a fresh continuation. No arithmetic hunting, no tolerance change, no push. Refs: ISSUE-LOCAL-01M7ZYAY4W7STQCBPSF6NQRF78 FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:hy4-flash-free [opencode]
The wave asked whether the oracle's il=0 k_proj equals the ggml kernel on the oracle's own captured inputs. It does, bit-for-bit, but only when the weight is routed through the CPU repack buffer, which selects ggml_gemm_q8_0_4x8_q8_0 for the nrc=4 prefill mul_mat. The same bytes and inputs through the plain-buffer multi-row vec_dot path differ by ~1e-6 of ULP dust, and that dust seeds the j=5 token flip. The fused-wqkv suspect is falsified at the oracle source: q, k and v are separate mul_mat ops. Decode (nrc=1) agrees on every route, which matches the golden prefix we already reproduce. Our token-major prefill issues one-row projections, so it can never reach the gemm tier; the repair is routing-only through vt::cpu::QuantRepackMatmul with a layer-major prefill pass for T>=2. Evidence, harness, capture results and the fix design are in the lane evidence directory. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…r inkling2 prefill Two shared-seam and one port repair, all red-first bit-proven against the pinned llama.cpp abca69200 oracle taps on the Inkling-2-Mini Q4_K_M arm. vt::cpu::QuantRepackMatmul's from_float quantizer rounded ties away from zero (scalar roundf) while ggml's aarch64 runtime tier (quantize_row_q8_0 / quantize_mat_q8_0_4x8, vcvtnq) rounds to even. One exact-.5 tie byte in the oracle's captured kproj_in row 3 corrupted a whole gemm row. New QuantizeRowQ8_0Runtime (nearest-even magic-number trick) now feeds both tiers; GemvRowQ8_0 accumulates with fused vfmaq_f32 to match ggml's arm gemv. Bit-proof vs the oracle taps: gemm tier 4096/4096 and gemv tier 1024/1024 BITWISE on the real captured rows (the earlier "already bit-proven" harness fed the reference the same roundf rule, so the tie class was invisible). test_quant_gemm_q80_bits re-pinned to the runtime tie rule with an explicit exact-.5 tie case; mismatches 0/6400 vs the real tap-build gemm kernel. inkling2_loop paged forward is layer-major for the projection dispatch: per-token input prep, then ONE Inkling2BatchedProj per repack-eligible Q8_0 projection over the whole prefill ubatch, then the sequential per-position conv/cache/attention/MoE stage. Decode (T==1) keeps the proven arms. inp_sa is captured before the norms because it feeds the residual; SWA layers carry empty k_conv_proj shapes and are guarded. Hermetic suites green; the golden-modes chat failure is byte-identical at HEAD f68f1ad47 (stash-baseline) and is therefore pre-existing. Per-op adjudication at the failing k_proj positions (PROCESS.md wave 5): with the tie fix, m=1 mmla == repack-gemm BITWISE on every captured row, so the wave-3 scalar-order premise is falsified and the residual drift sits downstream in the conv/clip path. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
… conv to ggml Wave-6 bitwise taps at il0 on the 5-token prompt under the [1]+[4] chunk config prove the static short conv was already exact, while the clip used one fused scale factor, rms-norm divided instead of multiplying by the reciprocal, and the short conv fused static and dynamic taps into one f64 sum. ggml executes two rounded multiplies for the clip (ggml_scale(ggml_l2_norm(x,t),t)), a reciprocal-multiply rms-norm, and a staged f32 conv (f32 sequential static sum in ggml_ssm_conv, then per-lag f32 dynamic adds). With the restage, chunk-2 tokens 0-2 go from ~1e-3 to 0/1024 bitwise against the oracle taps; the remaining t3 divergence is upstream one-ULP dust in the attention path transmitted through q8 activation-quantization boundaries. New hermetic tests pin the discriminating f32 cases; they fail under the old arithmetic. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…roof Re-lands the wave-5 adjudication record whose commit failed the trailer gate, and records wave-6: the conv/clip stage proof (static conv bitwise, clip/rms/conv staged-arithmetic repairs, chunk-boundary history carry verified), the pinned remaining mechanism (upstream attention ULP dust transmitted through q8 quantization at prefill row 3), and the bounded raw gate leg (j=5 unflipped; raw[2] 21->33, raw[4] 6->68 improved). FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…vec_dot_f16_f32 The inkling2 attention mirror Inkling2AttentionStep scored keys with a double-accumulating scalar dot while the pinned oracle's flash_attn_ext CPU kernel executes ggml_vec_dot_f16_f32 (the K cache row is F16), whose NEON branch widens the F16 key to F32 and runs ggml_vec_dot_f32 per 64-element chunk with the chunk results summed in ggml_float; and the tree's -ffp-contract=off build left the online-softmax recurrence S = S*ms + vs as multiply-then-add while the oracle binary contracts it to one fmaf. Add Inkling2DotF32Vec (transcription of ggml_vec_dot_f32's non-SVE NEON branch: four f32 accumulator vectors, step 16, pairwise tree reduce, the executed binary's fmul+fadd groups-of-4 tail and explicit-fma remainder) and Inkling2DotF16F32 (the f64-accumulated per-64-chunk wrapper), make the two softmax recurrences explicit fma, and pin both kernels with bit-exact goldens captured from the live libggml-cpu.so of the pinned tap build under the project's own -ffp-contract=off flags, each with a guard so the pin stays discriminating. Evidence: bitwise il0 chunk1 taps att_raw 640/3072 -> 0/3072 against oracle taps.0001 (vclip 118/1024 and rclip 16/384 keep pre-existing 1-ULP dust, unchanged from the wave-6 capture, so the kernel is exact given its rounded inputs); raw-only gate raw[0] first bad moves j=5 -> j=21 (the 161721 near-tie flips) and raw[2] j=33 -> j=21, doctest 361 passed | 438 failed, exit 1. Mutant captures ours-w6c.bin (scalar dot, att_raw 640) and ours-w7.bin (single-128 reduction, att_raw 485) stay red. Remaining mechanism named in PROCESS.md: post-attention chain (wo_raw/attn_out/l_out dust) and the vclip/rclip projection-input dust. Hermetic suites 9/9 green; preflight --staged exit 0. No shared vt:: op touched; no checker weakened; no tolerance tuning. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…ing and attn-res mix to ggml The chunk-1 il0 tap bisect (extended oracle instrument with in2, wvproj, relproj, gate_raw, wo_in and mix_states/mix_probs taps) proved the vclip and rclip one-ULP dust enters after bitwise projection inputs: every norm mirror squared in double where ggml squares in f32 and widens the rounded product, and Inkling2AttnRes divided by rms where ggml scales by the reciprocal. The gate_raw dust came from routing wqkv_gate and wo through the plain DotQ8_0 MatVec instead of the repack-gemm tier every other projection uses, and the mix dust from a double logits dot, per-element softmax division and a mul+add weighted sum where the oracle executes the NEON vec dot, the ggml_v_expf soft_max with a reciprocal scale and a sequential-f32 fma combine. After the fixes every chunk-1 il0 tap from attn_in through ffn_norm is bitwise 0-mismatch against oracle abca69200; the remaining dust is isolated to the MoE (1771/2304), named for the next wave with its candidate sites. Two new fixture tests reproduce the oracle rows bitwise and run red against the stashed old arithmetic (748 failed assertions). Raw gate: raw[5] is exact for its full 128 tokens (first leg all-green); raw[0] j=5 stays red through the still-dusted MoE near-tie. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
… SITU and NVFP4 expert dot to ggml The il0 chunk-1 MoE stage diverged at the router logits: the F32 ffn_gate_inp weight ran through the double-accumulating scalar dot while the oracle's F32 traits execute the NEON ggml_vec_dot_f32 branch. The weight normalization divided once in double where ggml stages an f32 sum, an f32 scale_bias eps=1e-20 add and an f32 div; the SITU beta scales divided where ggml multiplies by the reciprocal across two rounded scales; and DotNvfp4Q8_0 transcribed the scalar fallback of ggml_vec_dot_nvfp4_q8_0 while the pinned oracle binary executes the NEON DOTPROD branch (two sdot chains, one vpaddq into four sumi lanes, four fma lanes, pairwise reduce), which the il0 chunk-1 moe tap showed as 1713/2304 @9.5e-7 after the router fix. All four are model-local repairs in the inkling2 mirror. The il0 chunk-1 tap is now bitwise end to end (ffn_norm through l_out, including moe_logits/probs/sel/weights/situ/down/weighted/moe), and the raw gate ladder moved from first-bad j=91/21/83/68 on four legs to all eight probe tokens matching on five of six legs; raw[0]'s byte-identical j=5 near-tie remains and is named (layers il>=1, decode regime, chunk2 beyond il0) in the wave-9 PROCESS record. DotNvfp4Q8_0 carries a six-golden bitwise pin against the live libggml-cpu.so that fails 4/6 under the retired scalar arm. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…tive-bias dot; prove il>=1, chunk-2 and decode-1 bitwise Wave 10 of the Inkling-2-Mini W1 lane. Tap instrumentation widened to all layers on both sides; the bitwise-proven window now covers il0..il5 chunk-1 end-to-end, chunk-2 at every layer and position, and decode step 1; the decode dispatch is pinned to flash_attn_ext_f16_one_chunk for every graph the gate exercises (the >=512 split-kv regime is unexercised and recorded). Two fixes, both model-local: - The attention-sink softmax recurrence in Inkling2AttentionStep executed a fused fma; hex traces against the pinned oracle binary prove its sink site rounds unfused (mul-then-add) while the key-loop recurrence stays fused. The sink site is now unfused. Chunk-2 taps go from 108/3072 dust at il0 to 0/ALL at every layer and position. - The gathered relative-bias dot was a double-accumulating scalar sum while the oracle builds the table with ggml_mul_mat on F32 weights; it now runs Inkling2DotF32Vec and matches the oracle's gathered mask_row bitwise, pre- and post-F16. The remaining red is named: the AttnRes bank mix for three or more states (first dust at il6, 5e-7). Two mix hypotheses were tested and reverted after the gate regressed two 8-match legs. The raw gate stays red at the raw[0] j=5 near-tie (151663 vs 161721). Hermetic suites 9/9 green; preflight --staged exit 0. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
… ggml vec_dot_f32 The AttnRes bank-mix weighted sum executes ggml_vec_dot_f32 over the n states, and the executed binary contracts each 4-element group as fmul then fadd with a <=3 explicit-fma remainder. A plain ascending fma chain therefore validated bitwise at n<=2 while diverging at the first n=4 site (il12 ffn_mix 892/2304 ULP with bitwise states and probabilities — hex-traced against the widened oracle mix taps at on11). Inkling2AttnRes now gathers the state column and combines through Inkling2DotF32Vec, which is bit-exact against the live libggml-cpu.so at n=1..40 (80000/80000 probe) and leaves n<=2 unchanged by construction. Prefill chunk1 and chunk2 pass0 are now bitwise end-to-end at all 16 layers; the raw gate ladder is byte-identical to wave 10 and the remaining divergence is named as decode steps >= 2 (wave-10 proved only decode step 1). Adds the measurement-only VT_INKLING2_MIX_TAPS knob (allowlisted) and a hermetic pin whose mutation (reverting to the fma chain) is red. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…ec_dot_f32 The loop-control projections (loop_*_ctrl_down/gain/forget are F32 in the GGUF) ran through the retired scalar double-accumulating Dot while the oracle's mul_mat F32 traits execute the NEON ggml_vec_dot_f32 (ggml-cpu.c 219-224). The F32 arm of Inkling2MatVec now calls Inkling2DotF32Vec, the wave-7-validated transcription. New hermetic pin "f32 MatVec dot bit-matches ggml_vec_dot_f32" (8 control-shaped rows, discriminating guard against the scalar arm; red under the scalar arm, green after). A new env-gated measurement-only decode-tap probe captures decode steps 2..N. Wave-12 bisect evidence (/tmp/ink2-w1-cap): oracle taps now cover decode steps 1..9 (LLAMA_GRAPH_REUSE_DISABLE=1 defeats llama-context graph reuse, llama-context.cpp:1835) and all 48 loop visits (il<=47); ours covered by the new probe. Decode steps 1..5 and prefill pass0 (il0..il17) are bitwise exact at every tap, including block pushes and bank/messages; the j>=5 divergence is real and lives in the loop-pass machinery: cycle1 ip6 attn_in first diverges (0.456) with bitwise loop_msg/bank/bank_out inputs, growing through cycles and the tail whose input is the last cycle's l_out. Gate (bounded raw, knob 16): raw[0] first-bad j=5 got moved 151663->220, want 161721; other legs unchanged. Next mechanism: the control op arithmetic and the attn_res_query row-count semantics (4/12-row tensors), not the dot tier. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…SS.md Append-only lane record: decode steps 1..5 bitwise exact, loop-pass cycle1 control named as the remaining mechanism, f32 MatVec fix and gate trajectory. Trailers on the preceding fix commit. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…rately The oracle control() concatenates cur and message along dim 1 into (n_embd, 2, tokens) and ggml_rms_norm then normalizes over ne00 = n_embd, so each half carries its own rms (ggml-cpu/ops.cpp:4269-4289) before the gate is reshaped to (2*n_embd, tokens) (inkling2.cpp:330-343). Our Inkling2Control normalized the joint 2*dim row instead: a different op that produced the wave-12 red of 0.456 at cycle1 ip6 attn_in despite bitwise inputs, weights, and messages. Fixed to the per-half form with ggml's scale arithmetic (double sum of f32-rounded squares, mean = float (sum/dim), scale = 1/sqrtf(mean + eps), y = x*scale). Also pinned the two wave-12 open questions from the actual GGUF: attn_res_query is [2304] (nq=1) on SWA layers and [2304,3] (nq=3) on full layers 5/11/17/23, so the caller's shape-based derivation is correct; all loop ctrl weights are F32 with byte digests recorded (blk.6.loop_q_ctrl_down sha e9dfda0c765bcd47). The caller pass structure (passes, bank handoff, per-pass messages) matches inkling2-loop.cpp:93-121. Red/green: the retired loop.py joint-rms reference pin was replaced by the ggml per-half form plus a discriminating pin; the pre-fix binary fails 24 assertions (w13-red.log) and the fixed suite passes 23/23 (195810 assertions). Decode-tap capture ours-w13.bin vs on13 shows cycle1 ip6 attn_in and cycle2 attn_in BITWISE 0/2304, l_out bitwise at both cycles, and greedy tokens equal the full oracle golden [152717,13,68014,32,13,161721,156021,68014,33,13]. Raw gate ladder (knob prefill_ubatch=16, bounded): 5 of 6 raw legs now exact through 128 tokens including raw[0]; the sole remaining red is the Translate 'good morning' leg at first-bad j=70. Chat leg untouched (pre-existing failure tracked separately). No shared vt:: op touched; no tolerance tuning; no checker weakened. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
… repack seam The Inkling2-Loop tail layers (20..23 of the UD-Q4_K_M artifact) store their MoE expert weights in a different quant arm than the head layers: ffn_down_exps is Q8_0 and ffn_gate_up_exps is Q5_K, where layers 0..19 are NVFP4. The oracle runs mul_mat_id on those tensors through the repack-buffer tiers (repack.cpp:5253 dispatch; gemv for one src1 row), so the vec_dot-tier dots our MoE used carry 1e-6-class dust on every tail-layer expert projection. That dust crossed a sampling near-tie at decode step j=70 of the raw "Translate 'good morning'" leg, the last red leg of the six-raw-prompt gate. This change routes Q8_0 expert weights through vt::cpu::QuantRepackMatmul, the wave-4 bit-proven transcription of both executed repack tiers, via a lazy per-layer repack cache keyed by (q8_raw pointer, expert). It is seam consumption only; no shared vt:: op changes. The Q5_K gate/up repack-gemv transcription is named in PROCESS.md as the next owed kernel and is not landed here, so the France leg's 15-error near-tie flip recorded in the gate run stands until it lands. Evidence: mutant capture ours-w14b (j=70 got 152416) vs fixed captures ours-w14c/ours-w14d (j=70 got 220, full oracle golden to step 75); bounded gate run w14-gate2.log (raw Translate all-128 exact, 5 clean legs hold, France regressed as described); hermetic suites green (ops 195810 assertions, loop gguf, gguf, dequant, nvfp4, quant bits, registry, loader); preflight --staged exit 0. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…nscribed repack+gemv tier Wave 15 of the Inkling-2-Mini W1 lane. Layers 20-23 ffn_gate_up_exps are Q5_K; the oracle (llama.cpp abca69200) runs mul_mat_id over them through repack_q5_K_to_q5_K_8_bl(8) plus ggml_gemv_q5_K_8x8_q8_K, while our side used the reference vec_dot tier whose 1-ULP dust flipped near-ties (wave 14: Translate fixed by the Q8_0 down arm, France regressed to 15 errors). The wave-14 staged probe mismatched the live library because its make_block packed only 48 scale bytes with the Q4_K high-bit scheme; the pinned make_block_q5_Kx8 packs 96 bytes in two 48-byte halves. New model-local TU inkling2_q5k_repack_gemv carries the repack, the 6-bit scale decode and the gemv verbatim, compiled with the surgical per-file +dotprod flag and gated on the shared HWCAP DotProd probe (VT_CPU_INKLING2_Q5K_DOT, default auto). Inkling2Moe routes Q5_K gate/up experts through a per-layer per-expert repack cache and one gemv over all 2*inter rows; our per-token MoE never reaches the M>3 gemm tier, so it is recorded unexercised, not transcribed. Bitwise vs the dlsym'd live libggml-cpu.so: gemv 2304/2304 on the staged real blk.20 bytes, 775296/775296 across 8 shapes x 48 activations, repack 11057024/11057024 bytes against the oracle's own exported repacker; the live symbol disassembles to the sdot/fmla tier this TU compiles to. QuantizeRowQ8_K re-proven bitwise (339012/339012). Red-first: the staged wave-14 probe mismatched 2304/2304 before this transcription. Mutation: unfusing one accumulator fma turns the new pin red (5 assertions); restored byte-for-byte. Two hermetic pins join test_inkling2_loop_ops: the kernel bit-pin against lib-captured words and the MoE reachability pin (one-hot down projection isolates wt*situ(gate,up); red if the dispatch stops selecting the tier). 12 hermetic suites green; bounded raw gate (prefill_ubatch=16, timeout 3600, flock held, MemAvailable 200G) exits 0 with 799/799 assertions: ALL 6 RAW LEGS ALL-128 EXACT, France's regression reversed. Chat mode not rerun (pre-existing 55-vs-71 failure tracked by the coordinator). No tolerance tuning, no checker weakened, no shared vt:: op touched. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
…ile the rebase onto main The row's exact-token gate is GREEN and stays green after the rebase onto origin/main 7b5a69d: a bounded raw rerun at the rebased HEAD under flock/MemAvailable-precheck/timeout gives 6/6 raw legs all-128 exact vs llama.cpp abca69200, doctest 799/799 assertions, exit 0. The spec gains ## Outcome (the measured gate, the falsified premises with their bitwise evidence pointers, the rejected defaults) and a completion ## Now; the chat-mode 55-vs-71 failure is recorded as PRE-EXISTING (reproduced byte-identically on the pre-campaign stash baseline at f68f1ad47) and coordinator-tracked, not chased; the Q5_K gemm tier and the flash split-kv (>=512) decode regime are recorded UNEXERCISED; the arm is aarch64-only per its DotProd/i8mm gating. Rebase reconciliation: 44 commits replayed onto main, six previously-applied ENG-CHUNKED-PREFILL duplicates dropped, the redundant seam-cherry-pick repair commit skipped. On the shared src/vt/cpu/cpu_quant_repack_arm.cpp, main does not carry the nearest-even QuantizeRowQ8_0Runtime (its QuantizeRowQ8_0 in cpu_quant_act.cpp is nearest-even but is not the repack path's quantizer), so this branch's runtime quantizer is kept; with it, the fused vfmaq_f32 Q8_0 gemm accumulation replaces main's recorded vmlaq deviation — cross-tier byte identity was a wrong invariant, superseded by per-tier oracle equality. tests/CMakeLists.txt takes the union of main's test_quant_repack_kq_repack block and this lane's tap-gated registrations, dropping the duplicate ungated test_ops_quant_repack target the union left. docs/ENVIRONMENT.md keeps both env rows. check-agent-record rot 0; preflight --staged exit 0. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [task]
The non-DotProd scalar fallback of GemvQ5K8x8Q8K voided k/s/vx/vy but not nc, failing -Werror=unused-parameter on the x86 and newest-gcc lanes. Syntax-verified clean under -Wall -Wextra -Werror on x86. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [maki]
…pack target The branch removed the duplicate ungated test_ops_quant_repack target from tests/CMakeLists.txt (the gated test_quant_repack_kq_repack replaces it), but the arm64-full lane still named the removed target in its build list and both VT_CPU_QUANT_REPACK env-var invocations, failing with 'No rule to make target'. Point all three references at the gated replacement. The lane's ISA probes fail on this runner independently (the CI-MAIN-CTEST-RESIDUE known-red); this fix only aligns the workflow with the tree's target reality. FOLLOWING_AGENTS_PROTOCOL Following-Agents-Protocol: true AI-Assisted: true Assisted-by: AGENT:zai/glm-5.3-flash [maki]
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
feat(NEW-CANDIDATE-PORTS): the Inkling-2-Mini W1 loop forward - exact token gate vs llama.cpp abca69200
Ports the Inkling-2-Mini loop architecture (inkling2 GGUF): GGUF
weights arm with census validation, the 48-visit loop-paged forward
(one packed attention cache + one packed short-conv state, dynamic
short conv on K/V, indexed attention layers, latent MoE with
NVFP4/Q8_0/Q5_K expert arms, loop control passes), tokenizer pre
mapping, registry + loader wiring, and the exact token gate: ALL 6
raw legs reproduce the llama.cpp abca69200 serving oracle for all 128
tokens (799/799 gate assertions; chat mode carries a PRE-EXISTING
failure 55-vs-71 reproduced on the pre-port stash baseline, recorded
in ## Owed and not chased).
The port consumes the shared quant seams (vt::cpu::QuantRepackMatmul
Q8_0 + the Q5_K repack gemv per-file dotprod-gated transcription) and
adds model-local ggml-exact forms transcribed from the pinned oracle
build and validated bitwise against the live libggml-cpu: the flash
attention dot set (chunked-f32 vec_dot_f16_f32, NEON vec_dot_f32 with
the executed binary's tail), gcc-contraction-faithful flash S
recurrences (sink recurrence rounds UNFUSED while the key loop
contracts - hex-trace pinned), rope as the f32 sequential theta chain,
clip as two rounded multiplies, rms/attention-res norms as
double-sum-of-f32-rounded-squares with reciprocal scale, the n-length
mix combine (association changes with n: sequential fma through 3,
fmul-then-fadd chain at 4), the MoE mirror (F32 NEON router dot,
NVFP4 DOTPROD expert dot, Q8_0/Q5_K repacked expert slices, silu as
ggml_v_expf), and the loop Control op with per-half rms and per-layer
attn_res_query rows (nq=3 on full layers 5/11/17/23, 1 on SWA, pinned
from the GGUF).
Along the way this PR corrects two shared-seam arithmetic facts with
bitwise evidence: QuantRepackMatmul's activation quantizer now rounds
ties nearest-even (vcvtnq) like the ggml runtime quantizers, and its
Q8_0 gemm accumulation is the fused vfmaq form (cross-tier byte
identity was a wrong invariant; per-tier oracle equality supersedes -
documented in the commit that changes it). The gate history and every
falsified premise (batch-shape parity, kernel class, scalar order,
fused wqkv, three wrong transcription targets, joint-rms control) are
recorded with bitwise pointers in the spec ## Outcome.
Aarch64-only per the DotProd/i8mm gating (VT_CPU_INKLING2_Q5K_DOT
documented in docs/ENVIRONMENT.md); Q5_K gemm tier and the flash
split-kv/tiled regimes are recorded unexercised in ## Owed.
FOLLOWING_AGENTS_PROTOCOL
Following-Agents-Protocol: true
AI-Assisted: true
Assisted-by: AGENT:zai/glm-5.3-flash [maki]